﻿using UnityEngine;
using System.Collections;

public class CharacterHandler : MonoBehaviour {

    private string ability1 = "";
    private string ability2 = "";
    private int health = 0;
    private int range = 0;
    private int speed = 0;

    // Use this for initialization
    void Start () {
        if (gameObject.tag == "character1") {
            gameObject.renderer.material.color = Color.green;
            ability1 = "abil1";
            ability2 = "abil2";
            health = 10;
            range = 1;
            speed = 2;
        } else if (gameObject.tag == "character2") {
            gameObject.renderer.material.color = Color.cyan;
            ability1 = "abil1";
            ability2 = "abil2";
            health = 10;
            range = 1;
            speed = 1;
        } else if (gameObject.tag == "character3") {
            gameObject.renderer.material.color = Color.magenta;
            ability1 = "abil1";
            ability2 = "abil2";
            health = 10;
            range = 1;
            speed = 2;
        } else if (gameObject.tag == "character4") {
            gameObject.renderer.material.color = Color.yellow;
            ability1 = "abil1";
            ability2 = "abil2";
            health = 10;
            range = 1;
            speed = 1;
        } else if (gameObject.tag == "character5") {
            gameObject.renderer.material.color = Color.red;
            ability1 = "abil1";
            ability2 = "abil2";
            health = 30;
            range = 2;
            speed = 2;
        }
    }

    void Update () {

    }

    void DamageHealth (int damage) {
        health -= damage;
    }

    void UseAbilityOne () {
        switch (gameObject.tag) {
            case "character1":

                break;
            case "character2":

                break;
            case "character3":

                break;
            case "character4":

                break;
        }
    }

    void UseAbilityTwo () {
        switch (gameObject.tag) {
            case "character1":

                break;
            case "character2":

                break;
            case "character3":

                break;
            case "character4":

                break;
        }
    }

    public string GetAbilOne () { return ability1; }
    public string GetAbilTwo () { return ability2; }
    public int getHealth () { return health; }
    public int getRange () { return range; }
    public int getSpeed () { return speed; }
}
